package QL;

import java.util.List;
import java.util.ArrayList;
import net.sf.json.JSONArray;
import net.sf.json.JSONObject;

public class ButlerKillFishLog implements IQLResponse
{
    /// <summary>
    /// 玩家Id
    /// </summary>
    public long UserId;

    /// <summary>
    /// 鱼Id
    /// </summary>
    public long FishId;

    /// <summary>
    /// 鱼名称
    /// </summary>
    public String FishName;

    /// <summary>
    /// 炮倍
    /// </summary>
    public long GunValue;

    /// <summary>
    /// 鱼倍率
    /// </summary>
    public long Multiple;

    /// <summary>
    /// 赢得金币数量
    /// </summary>
    public long WinCurrency;

    /// <summary>
    /// 创建时间
    /// </summary>
    public String CreateTime;

    @Override
    public void DeserializeFromJson(JSONObject jsonObj)
    {
        JSONObject t = jsonObj;
        if (t.has("user_id"))
            UserId = t.getLong("user_id");
        if (t.has("fish_id"))
            FishId = t.getLong("fish_id");
        if (t.has("fish_name"))
            FishName = t.getString("fish_name");
        if (t.has("gun_value"))
            GunValue = t.getLong("gun_value");
        if (t.has("multiple"))
            Multiple = t.getLong("multiple");
        if (t.has("win_currency"))
            WinCurrency = t.getLong("win_currency");
        if (t.has("create_time"))
            CreateTime = t.getString("create_time");
    }
}
